<div class="row">
	<div class="col-sm-12">
		<table id="grid"></table>
	</div>
</div>

<div id="win" style="display: none;">
	<div class="m-a-lg">
		<ul id="tab" class="nav nav-tabs">
			<li class="active">
				<a href="#tab1" data-toggle="tab" data-original-title="">Widget</a>
			</li>
		</ul>

		<form id="form" method="post" enctype="multipart/form-data">
			<input name="widget_id" type="hidden" autocomplete="off" />
			<div class="tab-content">
				<div id="tab1" class="tab-pane active m-t-lg">
					<div class="form-group">
						<label class="control-label">Name</label>
						<input name="widget_name" type="text" class="form-control easyui-validatebox" autocomplete="off" data-options="required:false" />
					</div>
					<div class="form-group">
						<label class="control-label">Category</label>
						<select id="category" name="widget_place" class="form-control" data-options="required:true" autocomplete="off">
							<?php if(count($categories) > 0): foreach($categories as $c): ?>
							<option value="<?= $c->cw_id ?>"><?= $c->cw_name ?></option>
							<?php endforeach; endif; ?>
							<option></option>
						</select>
					</div>
					<div class="form-group">
						<label class="control-label">Widget Order</label>
						<div>
							<input name="widget_order" type="text" class="form-control" autocomplete="off"/>
						</div>
					</div>
					<div class="form-group">
						<label class="control-label">Text</label>
						<textarea id="htmleditor" name="widget_source" class="form-control" style="height: 200px;" autocomplete="off"></textarea>
					</div>
				</div>
			</div>
		</form>
	</div>
</div>